
deployment=node[:deployment]

# TODO?  Wait for bindings to get registered wtihzk?
bash "Download File Bindings for MQ from the file server" do
    user node[:chef][:user]
    group node[:chef][:group]
    cwd "/tmp/"
    code <<-EOH
		scp #{node[:common][:scp_repo]}/generated/#{deployment}/OM_JNDI/.bindings /tmp
		chmod -R 755 /tmp/.bindings
    EOH
end

bash "Copy file bindings" do
    user node[:was][:user]
    group node[:was][:group]
    cwd "/tmp/"
    code <<-EOH
		mkdir -p #{node[:om][:installDir]}/OM_JNDI
		cp /tmp/.bindings #{node[:om][:installDir]}/OM_JNDI
	EOH
end
